from . import home
from flask import render_template, redirect, url_for


@home.route("/login/")
def login():
    """
    会员登录
    :return:
    """
    return render_template("home/login.html")


@home.route("/logout/")
def logout():
    """
    退出登录
    :return:
    """
    return redirect(url_for("home.login"))


@home.route("/register/")
def register():
    """
    注册
    :return:
    """
    return render_template("home/register.html")


@home.route("/user/")
def user():
    return render_template("home/user.html")


@home.route("/pwd/")
def pwd():
    return render_template("home/pwd.html")


@home.route("/comments/")
def comments():
    """
    评论
    :return:
    """
    return render_template("home/comments.html")


@home.route("/loginlog/")
def login_log():
    """
    登录日志
    :return:
    """
    return render_template("home/login_log.html")


@home.route("/movie_col/")
def movie_col():
    """
    电影收藏
    :return:
    """
    return render_template("home/movie_col.html")


@home.route("/")
def index():
    """
    首页
    :return:
    """
    return render_template("home/index.html")


@home.route("/animation/")
def animation():
    return render_template("home/animation.html")


@home.route("/search/")
def search():
    """
    搜索页
    :return:
    """
    return render_template("home/search.html")


@home.route("/play/")
def play():
    """
    播放页
    :return:
    """
    return render_template("home/play.html")
